<template>
<el-card class="box-card el-card-flex userFunction cardHover">
    <div slot="header" class="clearfix">
      <span><i class="el-title-adorn"> </i> 常用功能</span>
    </div>
    <div class="shortcut">
      <ul class="shortcut-ul">
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut1.png"><span>请假申请</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut2.png"><span>报销</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut3.png"><span>备用金</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut4.png"><span>用印申请</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut5.png"><span>转正</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut6.png"><span>出差申请</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut7.png"><span>离职</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut8.png"><span>招聘</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut9.png"><span>加班申请</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut1.png"><span>请假申请</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut2.png"><span>报销</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut3.png"><span>备用金</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut4.png"><span>用印申请</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut5.png"><span>转正</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut6.png"><span>出差申请</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut7.png"><span>离职</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut8.png"><span>招聘</span></li>
        <li class="shortcut-li el-box"><img src="@/assets/img/shortcut9.png"><span>加班申请</span></li>
      </ul>
    </div>
    <i @click="handDelProject" class="el-icon-close closeIcon"></i>
  </el-card>
</template>
<script>
export default {
  methods: {
    // 删除任意一个布局里的项目
    handDelProject () {
      this.$emit('handDelProject')
    },
  }
}
</script>
<style lang="scss">
.userFunction {
  padding: 0 10px;
  margin-bottom: 10px;
  position: relative;
  left: 0;
  top: 0;
  text-align: left;
  .closeIcon {
    position: absolute;
    right: 0;
    top: 0;
    padding: 3px;
    border-radius: 50%;
    background-color: #eeeeee;
    display: none;
  }
  .el-title-adorn {
		border-left: 3px solid #409EFF;
		display: inline-block;
		margin-right: 2px;
		height: 16px;
		vertical-align: middle;
		margin-top: -2px;
	}
  .shortcut {
    width: calc(100% + 25px);
    padding: 10px 0;
    overflow: auto;
    height: 122px;
    .shortcut-ul {
      float: left;
      width: calc(100% - 25px);
      .shortcut-li {
        float: left;
        width: 20%;
        text-align: center;
        white-space: nowrap;
        margin-bottom: 10px;
        justify-content: center;
        align-items: center;
        flex-direction: column;
        cursor: pointer;
        span {
          font-size: 12px;
          color: #333333;
        }
        img {
          width: 40px;
          height: 40px;
          // margin-bottom: 5px;
        }
        &:hover {
          span {
            color: #409EFF;
            text-decoration: underline;
          }
        }
      }
    }
  }
}
.cardHover {
  &:hover {
    background-color: rgba(254,227,78,.1);
    border: 1px dashed #fb9c68;
    .closeIcon {
      display: block;
    }
  }
}
</style>